<template>
  <div class="brandIndex">
    <Titile/>
    <div v-for="item of brandList" :key="item.id" >
      <div v-if="id == item.id">
        <div class="banner" >
        <!-- <img src="../../assets/yanxuan01.png" alt=""> -->
        <img :src="item.list_pic_url" alt="">
        <h2 >
          <!-- TEFAL制造商 -->
          {{item.name}}
        </h2>
        </div>
        <p >
          <!-- 严选对标国际品质，致力于高品质生活好物，执着寻求优质厨房电器供应商，携手WMF、Tefal制造商，打造高品质厨具。 -->
          {{item.simple_desc}}
        </p>   
      </div>
    </div> 
  </div>
</template>

<script>
import Titile from '../../components/BrandTitle.vue'
import {mapGetters} from 'vuex'

export default {
    name:'brand',
    components:{Titile},
    data() {
      return {
        id:this.$route.params.id,
      }
},
    mounted() { 
      // 请求action
      this.$store.dispatch("getHomeDB")
    },
    computed: {
      ...mapGetters(['brandList']),
     
    }
}
</script>

<style lang = 'less' scoped>
.brandIndex{

    font-size: .14rem;
    min-width: 320px;
    max-width: 800px;
    margin: 0 auto!important;
    line-height: 1;
}
.banner {
  width: 100%;
  position: relative;
  img {
    display: block;
    width: 100%;
  }
  h2 {
    position: absolute;
    left: 0;
    top: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    text-align: center;
    height: 30px;
    line-height: 30px;
    margin: auto;
    font-size: 20px;
    text-decoration: underline;
    color: #fff;
  }
}
p {
  background: #fff;
  font-size: 18px;
  text-align: center;
  padding: 20px 10px;
  line-height: 26px;
  color: #666;
}
</style>